home *** CD-ROM | disk | FTP | other *** search
- on playQT name, loc, fullscreen
- global movieID, QTEnd
- if length(movieID) = 0 then
- set movieID to QTMovie("OpenMovie", "Direct", the pathName & string(name), string(loc), "closedOnFinish", "fastIdle")
- end if
- if movieID contains "error" then
- put movieID
- beep()
- end if
- set QTEnd to QTMovie("Direct", movieID, "Get", "duration")
- QTMovie("Direct", movieID, "set", "currTime", 0)
- if fullscreen = 1 then
- QTMovie("Direct", movieID, "Set", "MovieRect", "0, 0, 640, 480")
- end if
- repeat while value(QTMovie("Direct", movieID, "Get", "currTime")) < value(QTEnd)
- QTMovie("Direct", movieID, "Idle")
- end repeat
- stopQT()
- end
-
- on playQTP name, loc, fullscreen
- global movieID, QTEnd, fullscreenG, LowBnd, lastFrame
- if length(movieID) = 0 then
- set movieID to QTMovie("OpenMovie", "Direct", string(name), string(loc), "closedOnFinish", "fastIdle")
- end if
- if movieID contains "error" then
- put "inside error"
- put movieID
- beep()
- end if
- set QTEnd to QTMovie("Direct", movieID, "Get", "duration")
- QTMovie("Direct", movieID, "set", "currTime", 0)
- if fullscreen = 1 then
- QTMovie("Direct", movieID, "Set", "MovieRect", "0, 0, 320, 240")
- else
- QTMovie("Direct", movieID, "Set", "MovieRect", "160, 140, 480, 380")
- end if
- set LowBnd to -1
- put "after LowBnd"
- QTMovie("Direct", movieID, "play")
- put "after play"
- put "movieID", movieID
- repeat while (value(QTMovie("Direct", movieID, "Get", "currTime")) < value(QTEnd)) and (value(QTMovie("Direct", movieID, "Get", "currTime")) > LowBnd)
- put "Above play Prvw"
- play frame "F3"
- end repeat
- stopQT()
- put "after stopQT"
- go(lastFrame)
- end
-
- on playQTF name, loc, fullscreen
- global movieID, QTEnd, fullscreenG, LowBnd, Current, lastFrame, CurrentAudio, Clips, gSpeed
- set movieID to QTMovie("OpenMovie", "Direct", string(name), string(loc), "closedOnFinish", "fastIdle")
- if movieID contains "error" then
- put "inside error"
- put movieID
- beep()
- end if
- set QTEnd to QTMovie("Direct", movieID, "Get", "duration")
- QTMovie("Direct", movieID, "set", "currTime", 0)
- set CurrentAudio to string(CurrentAudio)
- QTMovie("Direct", movieID, "Set", "audioLevel", CurrentAudio)
- if fullscreen = 1 then
- QTMovie("Direct", movieID, "Set", "MovieRect", "0, 0, 640, 480")
- else
- QTMovie("Direct", movieID, "Set", "MovieRect", "160, 140, 480, 380")
- end if
- set LowBnd to -1
- QTMovie("Direct", movieID, "play")
- if gSpeed = 2 then
- Forward()
- end if
- repeat while (value(QTMovie("Direct", movieID, "Get", "currTime")) < value(QTEnd)) and (value(QTMovie("Direct", movieID, "Get", "currTime")) > LowBnd)
- if Current = 1 then
- play frame "F2"
- next repeat
- end if
- if Current = 0 then
- play frame "F3"
- next repeat
- end if
- play frame "F4"
- end repeat
- if Current = 0 then
- if fullscreenG = 1 then
- ChangeScreenSize(Clips, "160,140", 0)
- end if
- end if
- updateStage()
- stopQT()
- if Current = 1 then
- go(19)
- else
- if Current = 0 then
- repeat with x = 13 to 17
- puppetSprite(x, 1)
- set the visible of sprite x to 1
- puppetSprite(x, 0)
- end repeat
- puppetSprite(19, 1)
- set the visible of sprite 19 to 0
- go(lastFrame - 1)
- repeat with x = 3 to 7
- puppetSprite(x, 1)
- set the visible of sprite x to 1
- puppetSprite(x, 0)
- end repeat
- set MovieSeq to 0
- setbar()
- updateStage()
- else
- if fullscreenG = 1 then
- ChangeScreenSize(Clips, "160,140", 0)
- end if
- go("Intro")
- end if
- end if
- end
-
- on stopQT
- global movieID, LastButton
- QTMovie("Direct", movieID, "Dispose")
- set movieID to EMPTY
- set LastButton to 0
- end
-
- on stopQTP
- global movieID, LastButton
- QTMovie("Direct", movieID, "Dispose")
- set movieID to EMPTY
- set LastButton to 0
- end
-
- on IdleQT
- global movieID, QTEnd
- QTMovie("Direct", movieID, "Idle")
- if value(QTMovie("Direct", movieID, "Get", "currTime")) >= value(QTEnd) then
- stopQT()
- end if
- end
-
- on pauseQT
- global movieID, LastButton
- put "inside pauseQT"
- QTMovie("Direct", movieID, "pause")
- set LastButton to 1
- end
-
- on unpauseQT
- global movieID
- put "unpauseQT"
- QTMovie("Direct", movieID, "play")
- end
-
- on restartQT name, loc, fullscreen
- global movieID, QTEnd
- put "inside restart QT"
- if length(movieID) = 0 then
- set movieID to QTMovie("OpenMovie", "Direct", the pathName & string(name), string(loc), "closedOnFinish", "fastIdle")
- end if
- if movieID contains "error" then
- put movieID
- beep()
- end if
- set QTEnd to QTMovie("Direct", movieID, "Get", "duration")
- if fullscreen = 1 then
- QTMovie("Direct", movieID, "Set", "MovieRect", "0, 0, 640, 480")
- end if
- repeat while value(QTMovie("Direct", movieID, "Get", "currTime")) < value(QTEnd)
- QTMovie("Direct", movieID, "Idle")
- end repeat
- stopQT()
- end
-
- on Rewind
- global movieID, gRewind, LowBnd
- if gRewind = 0 then
- QTMovie("Direct", movieID, "reverse")
- set gRewind to 1
- set LowBnd to 0
- end if
- end
-
- on Forward
- global movieID, gRewind, gSpeed, LastButton
- put "inside Forward"
- if gRewind = 1 then
- QTMovie("Direct", movieID, "reverse")
- set gRewind to 0
- end if
- set speed to 2.0
- set speed to string(speed)
- QTMovie("Direct", movieID, "Set", "rate", speed)
- set gSpeed to 2
- set LastButton to 1
- end
-
- on ChangeScreenSize name, loc, type
- global fullscreenG, movieID, QTEnd, gRewind, gSpeed, CurrentAudio
- if fullscreenG = 0 then
- if type = 1 then
- puppetSprite(48, 1)
- set the visible of sprite 48 to 1
- set the moveableSprite of sprite 48 to 1
- unLoadCast()
- QTMovie("Direct", movieID, "Set", "MovieRect", "0, 0, 640, 480")
- updateStage()
- end if
- QTMovie("Direct", movieID, "Set", "MovieRect", "0, 0, 640, 480")
- updateStage()
- set fullscreenG to 1
- else
- set gRewind to 0
- if type = 1 then
- puppetSprite(48, 1)
- set the moveableSprite of sprite 48 to 1
- set the locV of sprite 48 to the locV of sprite 48 + 1
- set the visible of sprite 48 to 0
- end if
- set CTime to QTMovie("Direct", movieID, "Get", "currTime")
- QTMovie("Direct", movieID, "Dispose")
- unLoadCast()
- set movieID to QTMovie("OpenMovie", "Direct", string(name), string(loc), "closedOnFinish", "fastIdle")
- if movieID contains "error" then
- put movieID
- beep()
- end if
- set QTEnd to QTMovie("Direct", movieID, "Get", "duration")
- QTMovie("Direct", movieID, "set", "currTime", CTime)
- set CurrentAudio to string(CurrentAudio)
- QTMovie("Direct", movieID, "Set", "audioLevel", CurrentAudio)
- QTMovie("Direct", movieID, "Set", "MovieRect", "160, 140, 480, 380")
- updateStage()
- if gSpeed = 2 then
- set speed to 2.0
- set speed to string(speed)
- QTMovie("Direct", movieID, "Set", "rate", speed)
- end if
- set fullscreenG to 0
- updateStage()
- end if
- end
-
- on IncreaseVol
- global movieID, CurrentAudio
- put "CurrentAudio", CurrentAudio
- set CurrentAudio to QTMovie("Direct", movieID, "Get", "audioLevel")
- if CurrentAudio < 255 then
- set CurrentAudio to CurrentAudio + 30
- end if
- set CurrentAudio to integer(CurrentAudio)
- set CurrentAudio to string(CurrentAudio)
- pauseQT()
- QTMovie("Direct", movieID, "Set", "audioLevel", CurrentAudio)
- unpauseQT()
- end
-
- on DecreaseVol
- global movieID, CurrentAudio
- set CurrentAudio to QTMovie("Direct", movieID, "Get", "audioLevel")
- put "decreaseVol"
- put "CurrentAudio", CurrentAudio
- if CurrentAudio > 50 then
- set CurrentAudio to CurrentAudio - 50
- else
- set CurrentAudio to 0
- end if
- set CurrentAudio to integer(CurrentAudio)
- set CurrentAudio to string(CurrentAudio)
- pauseQT()
- QTMovie("Direct", movieID, "Set", "audioLevel", CurrentAudio)
- unpauseQT()
- end
-